
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<script type="text/javascript">
		$(document).ready(function(){
		  // 在这里写你的代码...
			$('#addCatalog').hide();
			$('#editCatalog').hide();

			$('#controlType').change(function(){
				//alert($('#controlType').val());
				if ($('#controlType').val() == 1){
					$('#addCatalog').show();
					$('#editCatalog').hide();
				}
				if ($('#controlType').val() == 0){
					$('#editCatalog').show();
					$('#addCatalog').hide();
				}
			});
			
			
			
						
		});	
	</script>
	

<div class="pageContent">
	
	<div class="pageFormContent" >
		<select id="controlType" name="type">
			<option value="-1">--请选择操作类型--</option>
			<option value="1">新增产品子分类</option>
			<option value="0">编辑当前产品分类</option>
		</select>
	</div>
	
	<form method="post" action="__URL__/saveCatalog/navTabId/__MODULE__/parentid/{$parentid}/type_id/{$type_id}"  onsubmit="return local_validateCallback(this, dialogAjaxDone)" enctype="multipart/form-data">
		<div id="addCatalog" >
			<div class="pageFormContent" layoutH="100" >
	
				<div class="unit">
					<label>产品分类名称：</label>
					<input type="text" class="required" size="30" maxlength="20" name="name"  />
				</div>
				
				<div class="unit">
					<label>产品分类图片：</label>
					<input name="image" id="image" type="file" class="file huge" />
				</div>
				
				<div class="unit">
					<label>产品分类状态：</label>
					<select name="status">
						<option value="1">启用</option>
						<option value="0">禁用</option>
					</select>
				</div>
				
			</div>
			<div class="formBar">
				<ul>
					<li><div class="buttonActive"><div class="buttonContent"><button type="submit">提交</button></div></div></li>
					<li><div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div></li>
				</ul>
			</div>
			
		</div>
	</form>
	
	<!-- /////////////////////////////////////////////////////////////////// -->
	
	<!-- 产品信息修改 -->
	
	<form method="post" action="__URL__/editProductCatalog/navTabId/__MODULE__/id/{$parentid}/"  onsubmit="return local_validateCallback(this, dialogAjaxDone)" enctype="multipart/form-data">
		<div id="editCatalog" >
			<div class="pageFormContent" layoutH="100" >
				
				<div class="unit">
					<label>产品分类名称：</label>
					<input type="text" class="required" size="30" maxlength="20" name="name"  value="{$editCatalog['name']}"/>
				</div>
				<div class="unit">
					<label>产品分类图片：</label>
					<img src="__PUBLIC__/uploadfiles/files/common/{$editCatalog['imageurl_small']}">
				</div>
				
				<div class="unit">
					<label>产品分类图片上传：</label>
					<input name="image" id="image" type="file" class="file huge" />
				</div>
				
				<div class="unit">
					<label>产品分类状态：</label>
					<select name="status">
						<if condition=" $editCatalog['status'] eq '1'">
								<option value="1">启用</option>
								<option value="0">禁用</option>
							<else/>
								<option value="0">禁用</option>
								<option value="1">启用</option>
						</if>	

					</select>
				</div>
				
			</div>
			<div class="formBar">
				<ul>
					<li><div class="buttonActive"><div class="buttonContent"><button type="submit">提交</button></div></div></li>
					<li><div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div></li>
				</ul>
			</div>
		</div>
	</form>
	
</div>

